#pragma once
#include "Course.h"
#include <string>
#include "CourseException.h"
using namespace std;
class Mathematics : public Course
{
public:
	Mathematics(void);
	~Mathematics(void);
	Mathematics(string, char = '-');
	Mathematics(string, int, char = '-');

	char getGrade(){ return grade;};
	
	void setGrade(char g){
		if (g >= 'A' && g <= 'F'){
			grade = g;
		}
		else{
			char s[100];
			sprintf(s, "BAD GRADE! \nGrades allowed: A-F. \n Your input: %c", g);
			throw CourseException (s);
		}
	}
	virtual void print();
private:
	char grade;
};

